<link rel="stylesheet" type="text/css" href="|£|$url|\£|/wp-content/plugins/video-wizard/libs/Smarty/templates/css/palinsesto_creation.css"/>
<link rel="stylesheet" type="text/css" href="|£|$url|\£|/wp-content/plugins/video-wizard/libs/jqueryUI/css/ui-lightness/jquery-ui-1.8.16.custom.css"/>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/libs/jquery/jquery-1.6.2.min.js"></script>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/libs/jqueryUI/js/jquery-ui-1.8.16.custom.min.js"></script>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/js/palinsesto_creation.js"></script>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/libs/jwplayer/jwplayer.js"></script>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/js/checks.js"></script>
<script type="text/javascript" src="|£|$url|\£|/wp-content/plugins/video-wizard/js/utilities.js"></script>


<div id="palinsesto">
    <form method="POST" id="videoListForm">
    <div id="videoListContainer" class="floatl">
        <div id="palinsestoTitle">
            Titolo palinsesto:<br/>
            <input id="paltitle" type="text"  name="palinsestoTitle"/>
        </div>
        <div id="palinsestoTitle">
            <table>
                <tr>
                    <td>Data in onda</td>
                </tr>
                <tr>
                    <td>
                        <input id="onairDate" type="text" name="onairDate" value=""/>
                        <script>
                            $('#onairDate').datepicker({
                                dateFormat: 'dd/mm/yy'
                                }
                        );
                        </script>
                    </td>
                    <td>
                        <input type="button" value="Termina Palinsesto" onclick="submitPalinsesto();"/>
                        <input type="hidden" name="vidwiz-oper" value="vidwiz_create_palinsesto"/>
                    </td>
                </tr>
            </table>
        </div>
        
            <div id="videoList" class="floatl">
            <div id="animationTarget"></div>
                <script>
                redraw = function(event, ui) {
                        //senza lo 0 non funziona con chrome
                        ui.item.parent().hide().show(0);
                    };
                    $(document).ready(function() {
                    $("#videoList_tab").sortable({ 
                        opacity: 0.2, 
                        delay:30,
                        stop: redraw,
                        placeholder: "placeholder",
                        forcePlaceholderSize: true,
                        helper:"clone"}).disableSelection();
                    });
                </script>
                <table id="videoList_tab">     </table>
            </div>

            <div class="clr"></div>
            
        
    </div>
    
    </form>
    
    <form  name="searchVideosPalinsesto" class="floatl">
    <div id="searchBox">
        <div id="searchBar">
            <table id="searchBar_table">
                <tr>
                    <td>
                        Categoria:
                    </td>
                    <td>
                        Pubblicati a partire da:
                    </td>
                    <td>
                        Metatags:
                    </td>
                    <td></td>
                    <td></td>
                </tr>
                <tr>
                    <td>
                        <select name="categorySearch">
                            <option value='' >Tutte le categorie</option>
                            |£|foreach from=$categories item=category|\£|
                                <option value="|£|$category.term_id|\£|">|£|$category.name|\£|</option>
                            |£|/foreach|\£|
                        </select>
                    </td>
                <td>
                        <input id="dateSearch" type="text" name="dateSearch"/>
                        <script>
                            $('#dateSearch').datepicker({
                                dateFormat: 'dd/mm/yy'
                                }
                        );
                        </script>
                </td>
                
                <td>
                    <img width="" height=""/>
                    <input type="text" name="metatagSearch"/>
                </td>
                <td>
                <input onclick="searchVideos('searchResults');" type="button" value="Ricerca..."/>
                </td>
                <td class="pageNavTd"><img style="display:none;" class="pageNav" id="prevPagination" onclick="getNextResults('bck','searchResults');" src="|£|$url|\£|/wp-content/plugins/video-wizard/libs/Smarty/templates/img/arrowleft.png"/></td>
                <td class="pageNavTd"><img class="pageNav" |£|if $nextPagination != "true"|\£|
                             style="display:none;"
                         |£|/if|\£| id="nextPagination" onclick="getNextResults('fwd','searchResults');" src="|£|$url|\£|/wp-content/plugins/video-wizard/libs/Smarty/templates/img/arrowright.png"/></td>
            </tr>
        </table>
        </div>
        <div id="searchResults">
            |£|$palinsestoResults|\£|
        </div>
        <div class="clr"></div>
    </div>
    <div class="clr"></div>
    </form>
        <div class="clr"></div>
</div>    
        <div class="clr"></div>
<div id="eventi"></div><div class="clr"></div>